package com.egao.customer.biz;

import com.egao.common.core.damon.results.PageResult2;
import com.egao.common.system.entity.User;
import com.egao.customer.entity.Customer;
import net.sf.json.JSONObject;
import org.apache.poi.ss.formula.functions.T;
import java.util.List;

/**
 *
 * 数据层接口
 * @author : Doman
 * @date : 2020-06-13 13:36:04
 * @version ：1.0
 */
public interface CustomerBiz {

	/** 获取实体类表格
	 * @param page
	 * @param customer
	 * @return
	 */
	public JSONObject list(PageResult2<T> page, Customer customer, User loginUser) throws Exception;
	
	/**
	 * 获取实体类表格
	 * @param customer
	 * @return
	 */
	public List<Customer> list(Customer customer, User loginUser);
	
	/**
	 * 根据Id查询实体类
	 * @param customer
	 * @return
	 */
	public Customer getById(Customer customer);

	/**
	 * 根据Id查询实体类
	 * @param customer
	 * @return
	 */
	public Customer getByCard(Customer customer);

	/**
	 * 保存实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean save(Customer customer, User loginUser);
	
	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean update(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean updateState(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean cardUpdate(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean jf(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean updateYfk(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean yfk(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean updateTbState(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean violations(Customer customer, User loginUser);

	/**
	 * 修改实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean advanceChargeDiscount(Customer customer, User loginUser);

	/**
	 * 删除实体类
	 * @param customer
	 * @param loginUser
	 * @return
	 */
	public boolean remove(Customer customer, User loginUser);

}
